﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace suirui.ZhuMu.WebCore
{
    [AttributeUsage(AttributeTargets.Class, AllowMultiple = false)]
    public class AutoInjectAttribute : Attribute
    {
        public AutoInjectAttribute(Type interfaceType, InjectType injectType)
        {
            Type = interfaceType;
            InjectType = injectType;
        }

        public Type Type { get; set; }

        /// <summary>
        /// 注入类型
        /// </summary>
        public InjectType InjectType { get; set; }
    }

    /// <summary>
    /// 注入类型
    /// </summary>
    public enum InjectType
    {
        Scope,
        Single,
        Transient
    }
}
